
/**
 * @(#)BaseService.java 2017å¹´9æ28æ¥	ä¸å4:37:20 Copyrights (C) 2017é«å¾·ä¿¡æ¯ææ¯æéå¬å¸
 */
package com.wwy.monitor.service;

import com.autonavi.dyui.common.exception.BizException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 * (ç±»ååè½è¯´ææè¿°)
 * <p>
 * ä¿®æ¹åå²:											<br>
 * ä¿®æ¹æ¥æ    		ä¿®æ¹äººå   	çæ¬	 		ä¿®æ¹åå®¹<br>
 * -------------------------------------------------<br>
 * 2017å¹´9æ28æ¥ ä¸å4:37:20   fulianqiu     1.0    	åå§ååå»º<br>
 * </p>
 * @author fulianqiu
 * @version 1.0
 * @since JDK1.7*/
public class BaseService {
    public Logger logger = LoggerFactory.getLogger(this.getClass().getName());

    /**
     * 校验参数ï¼æ¥æ¶booleanç±»åçè¡¨è¾¾å¼ (ä¼ è¿æ¥çå¦ææ¯trueï¼è¯´ææ¯éæ³参数)
     * @param expression
     * @param code
     * @param errorMsg
     * @throws BizException*/
    public static void checkArgument(boolean expression, int code, String errorMsg) throws BizException {
        if (expression) {
            throw new BizException(code, errorMsg);
        }
    }
}